﻿<div class="ph-tabs">
    <ul>
        <li class="k-state-active">项目列表</li>
    </ul>
    <div>
        <div id="grid_subject" style="text-align: center"></div>
    </div>
</div>

<script class="init">
    LocatedMenu("国家标准", "项目列表");
</script>

<script class="grid_class_columns">
    var subjectFields = [{
        title: "项目名称",
        field: "SubjectName",
        width: 200,
        attributes: { style: "text-align:left" }
    }, {
        title: "单位",
        field: "Unit",
        width: 100
    }, {
        title: "适用年级",
        field: "AdapterGrade",
        template: "#=GetGradeString(AdapterGrade)#",
        attributes: { style: "text-align:left" }
    }];
</script>

<script class="grid_config">
    $(function () {
        $("#grid_subject").kendoGrid({
            columns: subjectFields,
            dataSource: Whale.dataSource({
                url: "/Standard/Subject/GetSubjects",
                pageSize: 0
            }),
            dataBound: function (e) {
                //让表头居中
                $("th.k-header").attr("style", "text-align:center; font-weight:bold;");
            }
        });
    });
</script>
